package com.HPUCA.QQchat.client;

import com.HPUCA.QQchat.entity.Account;

import java.io.IOException;

public class GetMessage implements Runnable{
    private Account user;

    public GetMessage(Account user) {
        this.user = user;
    }
    @Override
    public void run() {
        while (true){
            try {
                String msg = this.user.getRead().readLine();
                System.out.println(msg);
            } catch (Exception e) {
                e.printStackTrace();
            }
        }
    }
}
